package com.wiscamp.ninechapters.panels.application.vo;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import cube.ddd.application.ViewObject;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 菜单表
 */
@Data
public class MenuVO implements ViewObject {
    /**
     * 菜单编号
     */
    private long menuId = 0L;

    /**
     * 应用编号
     */
    private long applicationId = 0L;

    /**
     * 菜单代码
     */
    private String menuCode = "";

    /**
     * 菜单名称
     */
    private String menuName = "";

    /**
     * 菜单分组
     */
    private String menuGroup = "";

    /**
     * 序号
     */
    private int menuIndex = 0;

    /**
     * 菜单层级
     */
    private int menuLevel = 0;

    /**
     * 上级菜单编号
     */
    private long parentId = 0L;

    /**
     * 菜单图标
     */
    private String icon = "";

    /**
     * 页面地址
     */
    private String pageUrl = "";

    /**
     * 标识符
     */
    private String identifier = "";

    /**
     * 是否显示
     */
    private boolean visible = true;

    /**
     * 备注
     */
    private String remark = "";

    /**
     * 创建用户
     */
    private long creatorId = 0L;

    /**
     * 创建时间
     */
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    private LocalDateTime creationTime;

    /**
     * 编辑用户
     */
    private long modifierId = 0L;

    /**
     * 编辑时间
     */
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    private LocalDateTime modificationTime;

    /**
     * 是否可用
     */
    private boolean enabled = true;

    /**
     * 是否删除
     */
    private boolean deleted = false;

    /**
     * 创建人名称
     */
    private String creatorName = "";

    /**
     * 编辑人名称
     */
    private String modifierName = "";
}
